﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Drawing;
using System.Data;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using EnvDTE;
using EnvDTE80;
using System.IO;

namespace Vivid3DManager
{
    public partial class ManagerPanel : UserControl
    {
        public ManagerPanel()
        {
            InitializeComponent();
        }

        private DTE2 m_dte;
        // Reference to the Visual Studio DTE object


        /// <summary>
        /// Receives the VS DTE object
        /// </summary>
        public DTE2 DTE
        {
            set
            {
                m_dte = value;
            }
        }

        private void button3_Click(object sender, EventArgs e)
        {
            folderBrowserDialog1.ShowDialog();
            PATH_Engine.Text = folderBrowserDialog1.SelectedPath;
        }

        private void button1_Click(object sender, EventArgs e)
        {
            string app = NAME_App.Text;
            Directory.CreateDirectory("system/app/" + app + "/classes/");
            foreach (var f in new DirectoryInfo("system/app/appclasses/").GetFiles())
            {
                File.Copy(f.FullName, "system/app/" + app + "/classes/" + f.Name);
            }
        }

    }
}